package org.hsieh.tr.explore.dbsource.impl;

import java.util.ArrayList;
import java.util.List;

import org.hsieh.tr.explore.annotation.TreeNodeChildren;
import org.hsieh.tr.explore.annotation.TreeNodeLabel;
import org.hsieh.tr.explore.dbsource.ITableColumnEntity;

public class TableColumnImpl extends AbstractDBObj implements
	ITableColumnEntity {

    public String columnName;
    public String columnTypeName;
    
    @TreeNodeChildren
    public List<ColumnProperty> properties = new ArrayList<ColumnProperty>();

    @TreeNodeLabel(image = "icons/db/tr_column.png")
    public String getColumnName() {
	return columnName;
    }

    public void setColumnName(String columnName) {
	this.columnName = columnName;
    }

    public String getColumnTypeName() {
	return columnTypeName;
    }

    public void setColumnTypeName(String columnTypeName) {
	this.columnTypeName = columnTypeName;
    }

    public List<ColumnProperty> getProperties() {
	return properties;
    }

    public void setProperties(List<ColumnProperty> properties) {
	this.properties = properties;
    }

    public void addProperty(ColumnProperty property) {
	this.getProperties().add(property);
    }

}
